\documentstyle[11pt,maple,twoside,headings]{article}
%%
%% DEFINE PAGE LAYOUT 
%% including fancy headers and footers
%% 
\setlength{\marginparwidth}{50pt}
\setlength{\marginparsep}{5pt}
\setlength{\oddsidemargin}{0.625 in}
\setlength{\evensidemargin}{-0.625 in}
\setlength{\textheight}{21.5 cm}
\setlength{\textwidth}{6.25 in}
\setlength{\footskip}{1.36 cm}
\setlength{\topmargin}{-0.125 in}
%%
%% USE FANCY PAGESTYLE TO ALLOW PROPER HEADERS AND FOOTERS
%% (see man fancyheadings for details)
%%
\pagestyle{fancyplain}
\setlength{\footrulewidth}{0.6pt}
\setlength{\headrulewidth}{0.6pt}
\setlength{\plainheadrulewidth}{0.6pt}
\setlength{\plainfootrulewidth}{0.6pt}
\lfoot[\rm\thepage]{}
\cfoot{}
\rfoot[]{\rm\thepage}
%%
%%	HEADING command
\newcommand{\HEADING}[3]{
\par
\vspace{ 0.5 in} 
\par
{\samepage 
\thispagestyle{plain}
\nopagebreak[4] 
\noindent \hspace{-0.09 em}{\Huge \rm {#1}}\par 
\nopagebreak[4]
\vspace{0.5 ex} 
\nopagebreak[4]
\noindent {\Large \em {#2}}\par 
\nopagebreak[4]
\vspace{3 ex}
\nopagebreak[4]
\hrule
\vspace{3 ex}
\rhead[]{\fancyplain{}{#3}}
\lhead[\fancyplain{}{#3}]{}
}
}
%%
%% heading COMMAND
\newcommand{\heading}[1]{
\par
\vspace{2 ex}
\par\noindent{\Large \bf #1}
\vspace*{1 ex}
\par
}
%%
%% subheading command
\newcommand{\subheading}[1]{
\par
\vspace*{1 ex}
\par\noindent{\sc #1}
\vspace*{1 ex}
\par
}
\begin{document}
\input{paper1}
\end{document}
